export const getFatherColumn = (self) => {
  return [
    // {
    //   label: '页面名称',
    //   prop: 'name',
    //   search: true,
    //   display: false,
    //   hide: true,
    //   searchSpan: 5
    // },
    {
      label: '页面名称',
      prop: 'name',
      display: true,
      disabled: true,
      search: true,
      type: 'search',
      searchType: 'input',
      searchSpan: 5,
      appendClick: () => {
        self.openMenuModel();
      },
      rules: [
        {
          required: true,
          message: '请输入页面名称',
          trigger: 'blur'
        }
      ]
    },
    {
      label: '页面编码',
      prop: 'code',
      display: true,
      disabled: true,
      search: true,
      searchSpan: 5,
      rules: [
        {
          required: true,
          message: '请输入页面编码',
          trigger: 'blur'
        }
      ]
    },
    {
      label: '所属模块',
      prop: 'rootMenuCode',
      search: true,
      type: 'select',
      filterable: true,
      props: {
        label: 'name',
        value: 'code'
      },
      dicFormatter: (data) => {
        return data.data;
      },
      dicUrl: '/api/blade-system/menu/lazy-list?parentId=0',
      addDisabled: false,
      display: true,
      disabled: true,
      searchSpan: 5,
      rules: [
        {
          required: true,
          message: '请输入所属模块',
          trigger: 'blur'
        }
      ]
    },
    {
      label: '页面类型',
      prop: 'type',
      search: true,
      disabled: true,
      type: 'select',
      searchSpan: 5,
      dicData: [
        { label: '主页', value: 'PAGE' },
        { label: '搜索型', value: 'SEARCH' },
        { label: '列表型', value: 'LIST' },
        { label: '弹出框', value: 'DIALOG' }
      ],
      rules: [
        {
          required: true,
          message: '请输入页面类型',
          trigger: 'blur'
        }
      ]
    },
    {
      label: '平台类型',
      prop: 'platType',
      type: 'select',
      row: true,
      dicData: [
        { label: 'WEB', value: 'WEB' },
        { label: 'PDA', value: 'PDA' }
      ],
      rules: [
        {
          required: true,
          message: '请选择平台类型',
          trigger: 'blur'
        }
      ]
    },
    {
      label: '页面描述',
      prop: 'remark',
      type: 'textarea',
      span: 24
    }
  ];
};

export const sonColumn = [
  // {
  //   label: '页面名称',
  //   prop: 'name',
  //   search: true,
  //   display: false,
  //   hide: true,
  //   searchSpan: 5
  // },
  {
    label: '页面名称',
    prop: 'name',
    display: true,
    search: true,
    searchSpan: 5,
    rules: [
      {
        required: true,
        message: '请输入页面名称',
        trigger: 'blur'
      }
    ]
  },
  {
    label: '页面编码',
    prop: 'code',
    display: true,
    search: true,
    searchSpan: 5,
    rules: [
      {
        required: true,
        message: '请输入页面编码',
        trigger: 'blur'
      }
    ]
  },
  {
    label: '所属模块',
    prop: 'rootMenuCode',
    search: true,
    type: 'select',
    filterable: true,
    display: false,
    props: {
      label: 'name',
      value: 'code'
    },
    dicFormatter: (data) => {
      return data.data;
    },
    dicUrl: '/api/blade-system/menu/lazy-list?parentId=0',
    addDisabled: false,
    disabled: true,
    searchSpan: 5,
    rules: [
      {
        required: true,
        message: '请输入所属模块',
        trigger: 'blur'
      }
    ]
  },
  {
    label: '页面类型',
    prop: 'type',
    search: true,
    type: 'select',
    searchSpan: 5,
    dicData: [
      // { label: '主页', value: 'PAGE' },
      { label: '搜索型', value: 'SEARCH' },
      { label: '列表型', value: 'LIST' },
      { label: '弹出框', value: 'DIALOG' }
    ],
    rules: [
      {
        required: true,
        message: '请输入页面类型',
        trigger: 'blur'
      }
    ]
  },
  {
    label: '平台类型',
    prop: 'platType',
    type: 'select',
    row: true,
    dicData: [
      { label: 'WEB', value: 'WEB' },
      { label: 'PDA', value: 'PDA' }
    ],
    rules: [
      {
        required: true,
        message: '请选择平台类型',
        trigger: 'blur'
      }
    ]
  },
  {
    label: '页面描述',
    prop: 'remark',
    type: 'textarea',
    span: 24
  }
];
